package com.greathf.hf_ywgl.expction;

import com.greathf.hf_ywgl.pojo.HF_Result;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.RestControllerAdvice;

@RestControllerAdvice
public class GlobalExcptionHandle {

    @ExceptionHandler(Exception.class)
    public HF_Result ex(Exception ex){
        ex.printStackTrace();
        return  HF_Result.error("0","服务器内部错误，请联系管理员！");
    }
}
